#ifndef RENDEREROPENGL_HEADER
#define RENDEREROPENGL_HEADER

#include "AbstractClasses\Renderer.h"

class RendererOpenGL : public Renderer {
private:

public:
	RendererOpenGL(WNDPROC);	// Construtor
	~RendererOpenGL();			// Destructor

	void ReSizeScene(int,int);		// Resize the window

	bool CreateAWindow(void);			// Create the OpenGL window
	void KillWindow(void);			// Destroy the OpenGL window

	void startDrawingScene(void);		// Start drawing the scene
	void stopDrawingScene(void);		// Stop drawing the scene

	void enterContext();
	void exitContext();
	void drawTriangle(POINT3D, POINT3D, POINT3D, COLOR);
	void drawRectangle(POINT3D, POINT3D, POINT3D, POINT3D, COLOR, bool);
	void drawLine(POINT3D, POINT3D, COLOR);
	void scale(POINT3D);
	void rotate(ORIENTATION);
	void translate(POINT3D);
	int LoadRawFile(LPSTR strName, int nSize, BYTE *pHeightMap, int sizex, int sizey);
	//void drawModel(char *modelName, float translatex, float translatey, float translatez,double angle);
	void drawPieceQuad(char texturename[10], GLfloat s, GLfloat t, GLfloat r, POINT3D position, ORIENTATION orientation, SCALE scale, int sizex, int sizey, COLOR color);
	void writeOnScreen(std::string s, GLdouble x, GLdouble y, int fontsize, COLOR color);
protected:
	HGLRC hRC;			// Permanent Rendering Context
	int InitGL(void);		// Initialize the OpenGL settings
	GLuint textures[10];
	char* texturesLoaded[10];

};

#endif
